package com.llf.simpleFactory;

/**
 * @author llf
 * @date 2022/1/21 10:22
 */
public class CarFactory  {
    public static Car getCar(String name){
      if ("五菱宏光".equals(name)){
            return new Wuling();
        }else if ("特斯拉".equals(name)){
            return new Tesla();
        }
            return null;

    }
}
